@(originRepository: Option[gitbucket.core.service.RepositoryService.RepositoryInfo],
  members: List[(String, String)],
  repository: gitbucket.core.service.RepositoryService.RepositoryInfo)(implicit context: gitbucket.core.controller.Context)
@import context._
@import gitbucket.core.view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
  @html.menu("network", repository){
    <ul class="nav nav-tabs fill-width pull-left">
      <li class="active"><a href="@url(repository)/network/members">Members</a></li>
    </ul>
    <h3>Members of the @repository.name Network</h3>
    <div class="block">
      @if(originRepository.isDefined){
        @avatar(originRepository.get.owner, 20)
        <span@if(repository.owner == originRepository.get.owner){ class="highlight"}>
          <a href="@url(originRepository.get)">@originRepository.get.owner</a> / <a href="@path/@originRepository.get.owner/@originRepository.get.name">@originRepository.get.name</a>
        </span>
      } else {
        @avatar(repository.repository.originUserName.get, 20)
        <span class="highlight">
          @repository.repository.originUserName / @repository.repository.originRepositoryName
        </span>
      }
      (origin)
    </div>
    @members.map { case (owner, name) =>
      <div class="block">
        @avatar(owner, 20)
        <span@if(repository.owner == owner){ class="highlight"}>
          <a href="@url(owner)">@owner</a> / <a href="@path/@owner/@name">@name</a>
        </span>
      </div>
    }
  }
}
